<template>
  <el-dialog
    :append-to-body="true"
    :before-close="handleClose"
    :close-on-click-modal="false"
    :close-on-press-escape="false"
    :title="dialogData.title"
    :visible.sync="isDialog.visible"
    top="5vh"
    width="750px"
  >
    <div class="header-box"></div>

    <div class="flex-content">
      <el-form label-position="right" label-width="auto">
        <el-form-item label="商品名称">
          <el-input
            v-model="info.goods_data.name"
            disabled
            type="text"
          ></el-input>
        </el-form-item>

        <el-form-item label="市场价">
          <el-input
            v-model="info.goods_data.market_price"
            disabled
            type="text"
          ></el-input>
        </el-form-item>

        <el-form-item label="运费">
          <el-input
            v-model="info.goods_data.freight"
            disabled
            type="text"
          ></el-input>
        </el-form-item>
      </el-form>
    </div>
  </el-dialog>
</template>

<script>
export default {
  name: "Info",
  props: {
    info: {
      type: Object,
    },
  },
  data() {
    return {
      // 数据
      dialogData: {
        title: "",
      },
      dataInfo: {},
      // 弹窗
      isDialog: {
        visible: true,
      },
    };
  },
  created() {
    this.dialogData.title = "拼团商品";
  },
  methods: {
    // 关闭
    handleClose() {
      this.$emit("close");
    },
  },
};
</script>

<style lang="scss" scoped>
.el-table {
  min-height: 60vh;
}

::v-deep .el-dialog__body {
  padding: 20px 20px;
}

.header-box {
  display: flex;
  justify-content: flex-end;

  > div {
    margin-right: 10px;
  }
}

.flex-content {
  margin-top: 10px;
}
</style>
